const Type = require('../../model/type/Type')

function add(req,res){

 
 
  Type.create({typename: req.body.type}, (err,result)=>{
    if(err){
      res.json({
        code:0,
        msg: '增加失败'
    })
    }else{
      res.json({
        code:1,
        msg: '增加成功'
    })
    }
  })
  
}
module.exports = add